package com.goat.train.common.exception;

import lombok.Data;

@Data
public class BusinessException extends RuntimeException {
    private BusinessExceptionEnum businessExceptionEnum;

    public BusinessException(BusinessExceptionEnum businessExceptionEnum) {
        super(businessExceptionEnum.getMessage());
        this.businessExceptionEnum = businessExceptionEnum;
    }

    @Override
    public synchronized Throwable fillInStackTrace() {
        return this;
    }
}
